/**
 * Created by lf on 2015/3/26.
 */
var mongoose = require('mongoose');
var Article = mongoose.model('article', {
    title: String,
    content: String,
    author: String,
    create_date : { type: Date, default: Date.now}
});
var createArticle = function(title, content, author){
   return new Article({
        title: title||'',
        content: content||'',
        author: author||''
    });
}
exports.createArticle = createArticle;